package com.caifu.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;

import com.caifu.pojo.YlAssessmentRecord;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;


import java.util.Map;

/**
 * <p>
 * 长护险评估记录表 Mapper 接口
 * </p>
 *
 * @author 
 * @since 2020-11-09
 */
public interface YlAssessmentRecordMapper extends BaseMapper<YlAssessmentRecord> {

    /**
     *
     * 功能描述：查询评估等级信息
     *
     * @Param   userNo 用户编号
     * @Return
     * @Exception
     * @Author  GZ
     * @Date   2020/11/12 17:40
     */
    @Select({"<script>",
            "select c.COST_NAME,r.VALID_DATE from yl_assessment_record r inner join yl_cost c on r.cost_no=c.COST_NO",
            "where r.is_effective='1' and  r.USER_NO=#{userNo}",
            "</script>"})
    Map<String,Object> queryAssessmentInfo(@Param("userNo") String userNo);
}
